package com.net355.eblog.util;

import java.io.Serializable;
import java.util.List;


public class DataResult implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1632257345228489327L;
	private boolean isTrue;
	private String message;
	private Object tag;
	private PaginationSupport ps;
	private List<?> items;

	/**
	 * 运行结果
	 * 
	 * @param isTrue
	 * @param ps
	 * @param message
	 * @param tag
	 */
	public DataResult(boolean isTrue, PaginationSupport ps, String message, Object tag) {
		this.setIsTrue(isTrue);
		this.setPs(ps);
		this.setMessage(message);
		this.setTag(tag);
	}

	/**
	 * 运行结果
	 * 
	 * @param isTrue
	 * @param items
	 * @param message
	 * @param tag
	 */
	public DataResult(boolean isTrue, List<?> items, String message, Object tag) {
		this.setIsTrue(isTrue);
		this.setItems(items);
		this.setMessage(message);
		this.setTag(tag);
	}

	/**
	 * 运行结果
	 * 
	 * @param isTrue
	 * @param message
	 * @param tag
	 */
	public DataResult(boolean isTrue, String message, Object tag) {
		this.setIsTrue(isTrue);
		this.setMessage(message);
		this.setTag(tag);
	}

	/**
	 * 运行结果
	 * 
	 * @param isTrue
	 * @param message
	 */
	public DataResult(boolean isTrue, String message) {
		this.setIsTrue(isTrue);
		this.setMessage(message);
	}

	public boolean getIsTrue() {
		return isTrue;
	}

	public void setIsTrue(boolean isTrue) {
		this.isTrue = isTrue;
	}

	public String getMessage() {
		return message;
	}

	public PaginationSupport getPs() {
		return ps;
	}

	public void setPs(PaginationSupport ps) {
		this.ps = ps;
	}

	public List<?> getItems() {
		return items;
	}

	public void setItems(List<?> items) {
		this.items = items;
	}

	public void setMessage(String message) {
		this.message = message;
	}

	public Object getTag() {
		return tag;
	}

	public void setTag(Object tag) {
		this.tag = tag;
	}
}
